package cn.buddha.jec.exception.model;

import lombok.Getter;
import lombok.Setter;

import java.io.Serializable;

/**
 * @ClassName TongExceptionResult
 * @Author 友野浩二
 * @Description 存储返回给外系统或者前端的错误码和错误消息
 * @Version 1.0
 */
@Setter
@Getter
public class TongExceptionResult implements Serializable {

    private static final long serialVersionUID = -7393066081035082131L;

    private String retCode;
    private String retMsg;

    private TongExceptionResult(String retCode, String retMsg) {
        this.retCode = retCode;
        this.retMsg = retMsg;
    }

    public static TongExceptionResult exception(String retCode, String retMsg) {
        return new TongExceptionResult(retCode, retMsg);
    }
}
